﻿@model Exception

@{
    ViewBag.Title = "An error has occured!";
}

<div class="row wrapper border-bottom white-bg page-heading">
    <div class="col-lg-10">
        <h2>An error has occured!</h2>
        <ol class="breadcrumb">
            <li>
                Error Page
            </li>
        </ol>
    </div>
    <div class="col-lg-2"></div>
</div>

<div class="wrapper wrapper-content animated fadeInRight">
    <div class="row">
        <div class="col-lg-8">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <span>An error has occured while trying to process your request. Please contact your administrator.</span>
                </div>
                <div class="ibox-title">
                    <h3>Error Details</h3>
                    <span>
                        @if (Model != null)
                        {
                            if (Model.InnerException != null)
                            {
                                if (Model.InnerException.InnerException != null)
                                {
                                    if (Model.InnerException.InnerException.InnerException != null)
                                    { @Model.InnerException.InnerException.InnerException.Message }
                                    else
                                    { @Model.InnerException.InnerException.Message }
                                }
                                else
                                { @Model.InnerException.Message }
                            }
                            else
                            { @Model.Message }
                        }
                        else
                        {  }
                    </span>
                </div>
                <div class="ibox-content">

                    @using (Html.BeginForm("Index", "Home", FormMethod.Post, new { id = "errorForm" }))
                    {
                        <fieldset>
                            <button type="submit" id="btnDelete" class="btn btn-primary" >Home</button>
                        </fieldset>
                    }

                </div>
            </div>

        </div>
    </div>
</div>